package com.tssup.fesco.common.enums;

/**
 * @author shenx
 * @date 2016年7月11日
 * @see
 * @version
 */
public enum YesNoBoolean {

	YES("是", true),  NO("否", false), ;


	private String name;
	private Boolean value;

	private YesNoBoolean(String name, Boolean value) {
		this.name = name;
		this.value = value;
	}

	public static String getName(Boolean value) {
		if(null != value){
			for (YesNoBoolean t : YesNoBoolean.values()) {
				if (t.getValue().equals(value)) {
					return t.getName();
				}
			}
		}
		return null;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public Boolean getValue() {
		return value;
	}

	public void setValue(Boolean value) {
		this.value = value;
	}
	
	
}
